import {get,getREST,post,removeREST} from "@/utils/request"

export function insertItem(data){
    return post('workflowtemplate',data)
}

export function deleteTemplate(templateId){
    return removeREST('workflowtemplate/',templateId)
}

export function getPageList(search){
    return get('workflowtemplate/page',search)
}

export function insertFormDesign(data){
    return post('workflowtemplate/formDesign',data)
}

export function getFormItems(key){
    return getREST('workflowtemplate/formItems/',key)
}

export function getFlowDesign(key){
    return getREST('workflowtemplate/flowDesign/',key)
}

export function insertFlowDesign(data){
    return post('workflowtemplate/flowDesign',data)
}

export function getTemplateSelectList(){
    return get('workflowtemplate/select',null)
}

export function getTemplateForm(id){
    return getREST('workflowtemplate/',id)
}